package net.asrsmid.invoker.rs;

/**
 * @author Chen WANG
 * @version 1.0
 * @created 05-mai-2011 11:53:13
 */
public class WordDeviceInformation extends DeviceInformation {
	public static enum AUTOFIT_VALUES {NEVER, TRUE, FALSE, DEFAULT};

	public static final String AUTOFIT = "AutoFit";
	public static final String EXPAND_TOGGLES = "ExpandToggles";
	public static final String FIXED_PAGE_WIDTH = "FixedPageWidth";
	public static final String OMIT_HYPER_LINKS = "OmitHyperlinks";
	public static final String OMIT_DRILL_THROUGHS = "OmitDrillthroughs";

	/**
	 * 
	 * @param String
	 */
	public void setAutoFit(AUTOFIT_VALUES autoFit){
		if (autoFit == AUTOFIT_VALUES.NEVER)
			deviceInfoMap.put(AUTOFIT, NEVER);
		else if (autoFit == AUTOFIT_VALUES.TRUE)
			deviceInfoMap.put(AUTOFIT, TRUE);
		else if (autoFit == AUTOFIT_VALUES.FALSE)
			deviceInfoMap.put(AUTOFIT, FALSE);
		else
			deviceInfoMap.put(AUTOFIT, DEFAULT);
	}

	/**
	 * 
	 * @param value
	 */
	public void enableExpandToggles(boolean value){
		deviceInfoMap.put(EXPAND_TOGGLES, value ? TRUE : FALSE);
	}

	/**
	 * 
	 * @param value
	 */
	public void enableFixedPageWidth(boolean value){
		deviceInfoMap.put(FIXED_PAGE_WIDTH, value ? TRUE : FALSE);
	}

	/**
	 * 
	 * @param value
	 */
	public void enableOmitDrillthroughs(boolean value){
		deviceInfoMap.put(OMIT_DRILL_THROUGHS, value ? TRUE : FALSE);
	}

	/**
	 * 
	 * @param value
	 */
	public void enableOmitHyperlinks(boolean value){
		deviceInfoMap.put(OMIT_HYPER_LINKS, value ? TRUE : FALSE);
	}
}